package assignment2;
//Author Mark Mckillion, Date Completed 09/12/2011

@SuppressWarnings("serial")
public class Exceptions extends RuntimeException 
{   /*The purpose of this class it to create some run time execptions.
     *These will be used to inform the program/user of any errors incurred.
     *Run time exceptions occur when the program is active.*/
    
    public static class EmptyCollectionException extends RuntimeException
    {   public EmptyCollectionException() 
        {   //An exception that could happen is when the collection is empty.
            throw new RuntimeException("The current collection is empty.");
        }
    }

    public static class FullCollectionException extends RuntimeException 
    {   public FullCollectionException()
        {   //An exception that could happen is when the collection is full.
            throw new RuntimeException("The current collection is full.");
        }
    }
}